package cn.change360.newappchildrenenglish.utils;

import com.activeandroid.query.Select;

import java.util.List;

import cn.change360.newappchildrenenglish.mode.Integrations;

/**
 * Created by Jacky on 2015/11/19.
 */
public class IntegraUtil {

    /*
    * 获取总积分
    * */
    public static int getIntegration() {
        List<Integrations> list = new Select().from(Integrations.class).execute();
        int integrat = 0;
        for (Integrations integration : list) {
            integrat = integrat + integration.getIntegration_number();
        }
        return integrat;
    }
}
